package com.jzo2o.health.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.jzo2o.api.orders.ConsumerOrdersApi;
import com.jzo2o.api.orders.dto.request.OrderCancelReqDTO;
import com.jzo2o.api.trade.enums.PayChannelEnum;
import com.jzo2o.common.model.PageResult;
import com.jzo2o.health.model.domain.Orders;
import com.jzo2o.health.model.dto.request.OrdersPageQueryReqDTO;
import com.jzo2o.health.model.dto.request.PlaceOrderReqDTO;
import com.jzo2o.health.model.dto.response.*;

import java.util.List;

public interface IOrdersService extends IService<Orders> {
    PlaceOrderResDTO place(PlaceOrderReqDTO placeOrderReqDTO, Long id);

    OrderCancelReqDTO cancel(OrderCancelReqDTO orderCancelReqDTO, Long id);

    OrderCancelReqDTO refund(OrderCancelReqDTO orderCancelReqDTO);

    List<OrdersResDTO> page(Integer ordersStatus, Long sortBy);

    OrdersDetailResDTO getDetail(Long id);

    PageResult<OrdersResDTO> pageQuery(OrdersPageQueryReqDTO ordersPageQueryReqDTO);

    OrdersCountResDTO countByStatus();

    OrdersPayResDTO pay(Long id, PayChannelEnum tradingChannel);

    OrdersPayResDTO getPayResultFromTradServer(Long id);


//    OrdersPayResDTO pay(Long id, PayChannelEnum tradingChannel);
}
